package com.kehongborui.fliggy.service;

import com.kehongborui.fliggy.model.QueryVehicleModel;
import com.kehongborui.fliggy.model.VehicleModel;

import java.util.Date;
import java.util.List;

/**
 * @author zhang peng yang ming
 * @CopyRight (C) http://www.csdn.com
 * @brief
 * @email 122162005@qq.com
 * @date 2018-08-21
 */
public interface VehicleService {
    // 添加
    boolean create(VehicleModel vehicleModel);
    // 修改列车信息
    boolean update(VehicleModel vehicleModel);
    // 停用列车
    boolean delete(Long id);
    // 根据列车编号和日期查询车辆信息
    VehicleModel findByNoAndDate(String no, Date date);

    List<VehicleModel> findByDepArrStationAndDate(QueryVehicleModel queryVehicleModel);

    Integer getSeatsAmount(String vehicleNo);

    /**
     * 根据列车id 查询列车信息
     * @param id
     * @return
     */
    VehicleModel findById(long id);
}
